﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows.Controls;
using System.Windows;
using CommonInterfaces.Models;
using System.Windows.Input;

namespace StandardScriptItems.SimpleControls
{
    public class ScriptItemArgument : UserControl
    {
        Grid Griddy;
        UIElement InstructionDetails;
        TextBox arg;
        ElementStateComboBox arg1;

        public ScriptItemArgument(UIElement instructionDetails, String defaultText)
        {
            Name = "ArgumentPostfix";
            InstructionDetails = instructionDetails;
            Grid.SetColumn(InstructionDetails, 0);

            arg = new TextBox();
            arg.Name = "Argument";
            arg.Text = defaultText;
            Grid.SetColumn(arg, 1);

            Griddy = new Grid();
            Griddy.Name = "Griddy";
            Griddy.ColumnDefinitions.Add(new ColumnDefinition());
            Griddy.ColumnDefinitions.Add(new ColumnDefinition());
            Griddy.Children.Add(InstructionDetails);
            Griddy.Children.Add(arg);
            Content = Griddy;
        }

        

        public override string ToString()
        {
            return InstructionDetails.ToString() + " | " + arg.Text; ;
        }
    }
}
